Now Available!

Native .Net
Components

TList WinForms
for
.Net Framework

&

MetaDraw WinForms
for
.Net Framework



Bennet-Tec
Components
Make you
look sharp!



Home

Company

Products

Order Forms

How To

Downloads

Updates

Support

Registration

Dependencies

Links

Compatibility

Site Map


Basic How To


How To Insert, Find & Remove a Picture

Download VB Sample
Return to main How To Page

Picture embedding is supported through the ALLText External Object DLL, atx45pic.dll, provides full support for the direct embedding of images. No external OLE server is required. Supported picture formats include: BMP, DIB, WMF, JPG, and ICO. atx45pic.dll is responsible for the initial embedding of pictures, as well as for the manipulation of the objects: setting picture properties, displaying, printing, saving, restoring etc.

RegNewExtern Method

Description: Loads specified external Object DLL and registers it with ALLText.

Syntax:

ALLText.RegNewExtern noMsg%, "lpstrModule$"

Parameters:

noMsg% = 0 'FALSE - Display message box if the specified DLL is not found in the PATH.
noMsg% = -1 'TRUE - Show no error message
lpstrModule$ - Path to the ExtObjDLL for example "atx45pic.dll" or "C:\tmp\atx45pic.dll".

Example:

Sub Form_Load ()

With ATX451
.RegNewExtern -1, "atx45ole.dll"
.RegNewExtern -1, "atx45pic.dll"
End With

End Sub

Returns:

0 - if OK
<>0 - if an error occurred

Remarks: External object DLL`s must be registered before they can be used. They only need to be registered once each time the ALLText control is loaded into memory (not for each instance, or even for each form containing ALLText).

OLEObject Property

Description: Setting this property causes ALLText to call the specified External Object DLL to create and embed an External Object (eg: OLE Object or Picture) at the current caret location, overwriting any currently selected portion of the document. The type of object created is specified by the assigned string, ObjName$.

When read, this property returns a string indicating the name of the External Object DLL (atx45pic, atx45ole,...) supporting the object and an object number. If the object is an OLE object and the OLEVerb is set to anything other than ATX_Verb_Undefined, the OLE Server will be launched to executes this verb (ATX.OLEVERB) on this object. Note that this is true only for objects found immediately after caret, or an object marked with ink grabber frame when using ALLText/Pen.

The name of this property is a hold over from earlier versions of ALLText. In truth, the OLEObject property only initiates an OLE Link when calling the ATXOLE.DLL External Object DLL. Other external object libraries do not rely upon of OLE technology.

Access:
Read Write
Design - -
Run + +

Syntax: (see further notes below under Values)

ALLText.OleObject = s$
s$ = ALLText.OleObject

DataType: String

Values: On reading, ALLText returns a string identifying the Exteral Object DLL and the specific instance of the external object, ex: "ATXOLE ATXObj. #00001" or "ATXPic 0006"

When setting, the string s$ may be one of several forms depending upon the type of external object being embedded.

Ole Object - ALLText.OLEObject = OleServerName & "*" & FileName.
Ole Object - ALLText.OLEObject = External Object DLL Name &

Copyright© 2003 Bennet-Tec Information Systems, Inc. All rights reserved.